Skip to content

feat: Increase the presence of the Chinese language and multilingual capabilities - #18

Open
biliblihuorong wants to merge 11 commits into
deviffyy:mainfrom
biliblihuorong:codex/i18n-zh
Open

feat: Increase the presence of the Chinese language and multilingual capabilities#18
biliblihuorong wants to merge 11 commits into
deviffyy:mainfrom
biliblihuorong:codex/i18n-zh

Conversation

@biliblihuorong

Copy link
Copy Markdown

Added multilingual support and expanded the availability of simplified Chinese and traditional Chinese.

@deviffyy deviffyy left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reviewed the implementation and ran the verification suite. The localization direction is fine, but the current revision is not ready to merge.

The main issues to address are:

  • CI currently fails because several changed files do not pass Prettier. Please format the changes and make sure the complete pnpm verify command passes.
  • Language switching currently remounts the entire application through the app-wide {#key ...} block. Please use reactive localization state so changing the language does not reset application UI state.
  • The Total Spend metric selector now uses the incorrect accessible name, "Show Total Spend", which also breaks two frontend tests. It needs a separate translation key.
  • Persisted locale values need validation and a safe English fallback. The UI should also avoid mixed Chinese and English sentence fragments.
  • The localization tests should verify actual switching and fallback behavior rather than only checking source-code strings.
  • Cache the locale-specific Intl.NumberFormat instances instead of recreating them for every formatting call.
  • Revert the 0.3.3 to 0.3.4 version changes; release versioning is handled separately by the maintainer.

Please update the PR and ensure the full CI suite passes before the next review.

@biliblihuorong

Copy link
Copy Markdown
Author

Hi @deviffyy I’ve merged the latest upstream main and resolved the Windows dependency conflict in commit 85a94e1.

The previous review feedback has been addressed in the latest revisions. The updated CI workflow is currently awaiting maintainer approval. Could you please approve the workflow when convenient? Once the checks complete, I’d appreciate another review.

#18 (review)

Regarding the question you raised earlier, I'm very sorry that I mistakenly incremented the version number. At that time, the local Windows system already had the software that was supposed to run the AI, and I forgot to correct it and simply reverted it back.

@deviffyy

deviffyy commented Aug 1, 2026

Copy link
Copy Markdown
Owner

Thanks for the update. I approved the workflow and reviewed the latest revision. The previous review items have been resolved.

A few issues still need to be addressed before merge:

  • Allow partial locale catalogs with English fallback.
  • Use typed source/metric identifiers instead of passing translation keys from Rust or parsing English text in the frontend.
  • Correctly normalize Unix locale values and use complete locale-specific native tray templates with coverage for all pinnable metrics.
  • Localize the remaining OpenQuota-owned labels and source descriptions.
  • Use a single language state source and remove the unused translation keys and trailing import.
  • Fix the macOS Clippy failure caused by the unused Labels.open and Labels.customize fields.

Windows CI passes. Ubuntu hit what appears to be an unrelated flaky timing test. Please update the PR and add targeted tests for the locale and native mapping cases above; I’ll review it again once CI completes.

@biliblihuorong
biliblihuorong requested a review from deviffyy August 8, 2026 11:49

@deviffyy deviffyy left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update. This is getting closer, but there are still a few things to fix before we can merge it:

  • Usage source detection still parses the English sourceNote text, and some source notes are still rendered directly. Source semantics should come from typed backend data rather than display text.
  • The frontend and native layer resolve the system language separately, so they can end up using different languages on macOS or Linux. The resolved language should have a single source of truth.
  • The reset date calculation compares UTC days while displaying local time, which can show the wrong "Today" or "Tomorrow" label around midnight. Please preserve the local calendar-day behavior and cover the timezone boundaries with tests.
  • Metric labels are inferred from their ID suffixes. This already changes "Extra Balance" to "Extra Usage" and leaves labels such as "Daily" and "Monthly" untranslated. These should use explicit typed semantics rather than suffix inference.
  • The remaining OpenQuota-owned UI text should go through the localization catalog. Provider- or user-supplied values do not need to be translated.

These are the remaining blockers for this PR. Once they are fixed and CI passes on Windows, macOS, and Linux, we can review it again.

@biliblihuorong
biliblihuorong requested a review from deviffyy August 9, 2026 04:13
@deviffyy

deviffyy commented Aug 9, 2026

Copy link
Copy Markdown
Owner

Thanks for sticking with this. The latest revision is much closer, but the localization contract still uses string translation keys between Rust and the frontend, and the System language option is not reliable on macOS. A few app-owned labels also remain untranslated.

Please address these in one focused revision and make sure CI passes on Windows, macOS, and Linux. Once that’s done, I’ll do a final review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants